<template>
	<view class="searchs-bts">
		<view class="searchs">
			<view class="name">{{name}}</view>
			<input placeholder="请输入搜索关键字" v-model="text" class="inputs"/>
		</view>
		<view class="btn-arrow" @click.stop="btns"></view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				title: 'Hello',
				text:'',
				name:'',
				url:''
			 }
		 },
		 onLoad() {
		 	
		 },
		 methods:{
			 btns(){
			 	let self=this
			 	if(!self.text){
			 		uni.showToast({
			 			title: '请输入关键字',
			 			icon: 'none',
			 			duration: 2000
			 		});
			 		return
			 	}
			 	uni.navigateTo({
			 		url: '/pages/index/btdetail?text='+self.text
			 	});
				
			 	/**
			 	uni.showToast({
			 	    title: '标题',
			 		icon:'none',
			 	    duration: 2000
			 	});
				**/
			 }
		 }
	}
		 
		 
	
</script>

<style lang="scss">
	.searchs-bts{
		width: 100%;
		overflow: hidden;
		margin: 0rpx auto;
			.searchs{
				width: 90%;
				overflow: hidden;
				margin: 20rpx auto;
			}
			.btn-arrow{
				width: 128rpx;
				height: 128rpx;
				background: url(../../static/arrows.png) no-repeat center;
				background-size: 100%;
				margin: 20rpx auto;
				
			}
			.name{
				width: 98%;
				overflow: hidden;
				line-height: 48rpx;
				margin: 10rpx auto;
			}
			.inputs{
				width: 97%;
				margin: 10rpx auto;
				line-height: 88rpx;
				padding-left: 1%;
				border: 2rpx solid #333;
				border-radius: 20rpx;
				height: 88rpx;
				overflow: hidden;
			}
	}
	
</style>
